ActiveButtonWidget

constructor(title: Text, width: Int, height: Int, activeProvider: Supplier<Boolean>, pressAction: Consumer<ActiveButtonWidget>, background: ActiveButtonWidget.Background? = null)


constructor(titleSupplier: Supplier<Text>, width: Int, height: Int, activeSupplier: Supplier<Boolean>, pressAction: Consumer<ActiveButtonWidget>, background: ActiveButtonWidget.Background? = null)

Parameters

titleSupplier

Supplier<Text> - supplies the message/label for this button

width

Int - width of the widget

height

Int - height of the widget

activeSupplier

Supplier - Supplies whether this button is active or not

pressAction

Consumer - action to take when the button is pressed

background

Background, optional - a custom background identifier. needs to be a nine-patch sprite